package com.atguigu.eduservice.config;

import com.baomidou.mybatisplus.core.injector.ISqlInjector;
import com.baomidou.mybatisplus.extension.injector.LogicSqlInjector;
import com.baomidou.mybatisplus.extension.plugins.PaginationInterceptor;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;


/**
 * @Author : 李红磊
 * @Date : 2021/06/02/22:23
 * @Description :
 */
@Configuration
@MapperScan("com.atguigu.eduservice.mapper")
//@MapperScan("com.atguigu.eduservice.mapper")
public class MyConfigService {


    @Bean//逻辑删除插件
    public ISqlInjector iSqlInjector(){
        return new LogicSqlInjector();
    }

    @Bean//分页插件
    public PaginationInterceptor paginationInterceptor(){
        return new PaginationInterceptor();
    }





}
